﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Controls;
using System.Windows;
using System.Windows.Media;
using System.Collections;

namespace CommomFunctions
{
    public class Labels
    {
        protected ArrayList labels = new ArrayList();

        public Labels()
        {

        }

        public void setAllVisible()
        {
            for (int i = 0; i < labels.Count; i++)
                ((Label)labels[i]).Visibility = Visibility.Visible;
        }

        public void setAllHidden()
        {
            for (int i = 0; i < labels.Count; i++)
                ((Label)labels[i]).Visibility = Visibility.Hidden;
        }

        public void setContent(int ind, string content)
        {
            ((Label)labels[ind]).Content = content;
        }

        public string getContent(int ind)
        {
            return ((Label)labels[ind]).Content.ToString();
        }

        public void setVisibility(int ind, Visibility visibility)
        {
            ((Label)labels[ind]).Visibility = visibility;
        }

        public void setHeight(int ind, int height)
        {
            ((Label)labels[ind]).Height = height;
        }

        public void setMargin(int ind, Thickness margin)
        {
            ((Label)labels[ind]).Margin = margin;
        }

        public Label getLabel(int ind)
        {
            return ((Label)this.labels[ind]);
        }

        public ArrayList getLabel()
        {
            return (this.labels);
        }

        public Label this[int i]
        {
            get
            {
                return ((Label)this.labels[i]);
            }
            
        }        
    
    }
}
